import { http } from '../common/axios_config/axios_config.js'

export const getRoleList = data => http('role/list', data, 'GET')

export const getRoleListPage = data => http('role/listPage', data, 'GET')

export const addOrEditRole = data => http("role/addOrEdit",data,"POST")

export const delRole = data => http("role/del",data,"GET")

export const batchDelRole = data => http("role/batchDelete",data,"POST")

//角色分配菜单
export const setRoleMenu = (url,data) => http(url,data,"POST")

//根据角色id获取已分配权限的菜单
export const getRoleMenu = data => http("role/getRoleMenu",data,"GET")